package cn.itlight.basic.mapper;



import cn.itlight.basic.query.BaseQuery;

import java.util.List;

public interface BaseMapper<T> {

    /*
     * @Title: loadAll
     * @Description: TODO
     * @Author: TomLiu
     * @Version: 1.0
     * @Date:  2022/6/21 18:43
     * @Parameters:
     * @Return
     */
    List<T> loadAll();

    /*
     * @Title: loadById
     * @Description: TODO
     * @Author: TomLiu
     * @Version: 1.0
     * @Date:  2022/6/21 18:43
     * @Parameters:
     * @Return
     */
    T loadById(Long id);

    /*
     * @Title: remove
     * @Description: TODO
     * @Author: TomLiu
     * @Version: 1.0
     * @Date:  2022/6/21 18:43
     * @Parameters:
     * @Return
     */
    void remove(Long id);

    /*
     * @Title: update
     * @Description: TODO
     * @Author: TomLiu
     * @Version: 1.0
     * @Date:  2022/6/21 18:43
     * @Parameters:
     * @Return
     */
    void update(T t);

    /*
     * @Title: save
     * @Description: TODO
     * @Author: TomLiu
     * @Version: 1.0
     * @Date:  2022/6/21 18:43
     * @Parameters:
     * @Return
     */
    void save(T t);

    /*
     * @Title: queryData
     * @Description: TODO
     * @Author: TomLiu
     * @Version: 1.0
     * @Date:  2022/6/21 18:43
     * @Parameters:
     * @Return
     */
    List<T> queryData(BaseQuery baseQuery);

    /*
     * @Title: queryCount
     * @Description: TODO
     * @Author: TomLiu
     * @Version: 1.0
     * @Date:  2022/6/21 18:43
     * @Parameters:
     * @Return
     */
    Integer queryCount(BaseQuery baseQuery);

    /*
     * @Title: batchDel
     * @Description: 批量删除
     * @Author: TomLiu
     * @Version: 1.0
     * @Date:  2022/6/25 11:17
     * @Parameters:
     * @Return
     */
    void batchDel(Long[] ids);
}
